package xiaohao.order.exception;

import com.taobao.api.TaobaoResponse;

public class RateException extends Exception implements TopErrorCode {
	
	private static final long serialVersionUID = 7295576435302487413L;
	
	private TaobaoResponse response;

	public RateException(String message) {
		super(message);
	}
	
	public RateException(Throwable cause) {
		super(cause);
	}
	
	public RateException(TaobaoResponse response) {
		this.response = response;
	}
	
	public RateException(String message, Throwable cause) {
		super(message, cause);
	}

	@Override
	public String getErrorCode() {
		return response.getErrorCode();
	}

	@Override
	public String getMsg() {
		return response.getMsg();
	}

	@Override
	public String getSubCode() {
		return response.getSubCode();
	}

	@Override
	public String getSubMsg() {
		return response.getSubMsg();
	}
	
}
